﻿using System;
using System.IO;
using NUnit.Framework;
using CuaHangMayTinh.Utilities;

namespace KiemThu
{
    public class DataUtilTest
    {
        public class DataUtil_KiemThu
        {
            [Test]
            [TestCase("2")]
            [TestCase("a")]
            public void ToInt(object val)
            {
                DataUtil.ToInt(val);
            }

            [Test]
            [TestCase("213123")]
            [TestCase(1223)]
            [TestCase(12.5)]
            [TestCase("")]
            public void ToString(object val)
            {
                DataUtil.ToString(val);
            }

            [Test]
            [TestCase("21313")]
            [TestCase("34")]
            [TestCase("asdfghj")]
            public void ToDecimal(object val)
            {
                DataUtil.ToDecimal(val);
            }

            [Test]
            [TestCase(21313)]
            [TestCase("2342s")]
            public void KTToDecimal(object val)
            {
                DataUtil.KTToDecimal(val);
            }
        }
    }
}
